import { ref } from 'vue';

import { PrimaryTableCol, TableRowData } from 'tdesign-vue-next';
import { CommonAnyData } from '@/api/model/common';

import WorkingView from '../working.vue'
import OpexView from '../opex.vue'
import StorageView from '../storage.vue'
import TimeView from '../time.vue'
import LogsView from '../logs.vue'

export const tabList = ref([
  { label: '运行情况', value: 'working' },
  { label: '运维', value: 'opex' },
  { label: '存储管理', value: 'storage' },
  { label: '时间校准', value: 'time' },
  { label: '运维日志', value: 'logs' },

]);

export const componentsMap: CommonAnyData = {
  working: WorkingView,
  opex: OpexView,
  storage: StorageView,
  time: TimeView,
  logs: LogsView,
};

export const INIT_DATA = ref([
  { label: 'DHCP', value: false, key: 'SwitchView' },
]);

export const columns: PrimaryTableCol<TableRowData>[] = [
  { colKey: 'sn', title: '设备序列号', align: 'center' },
  { colKey: 'dev_name', title: '设备名称', align: 'center' },
  { colKey: 'opt', title: '操作', fixed: 'right', align: 'center', width: 360 },
];
